package book;

public class BookList {
    private Book[] book = new Book[10];
    private int usedSize;

    public BookList() {
        book[0] = new Book("三国演义", "罗贯中", 17, "小说");
        book[1] = new Book("西游记", "吴承恩", 47, "小说");
        book[2] = new Book("水浒传", "施耐庵", 37, "小说");
        this.usedSize = 3;
    }

    public int getUsedSize() {
        return usedSize;
    }

    public void setUsedSize(int usedSize) {
        this.usedSize = usedSize;
    }

    public Book getPos(int pos) {
        return this.book[pos];
    }

    public void setBook(int pos, Book book) {
        this.book[pos] = book;
    }
}

